import {localeProps} from '../../utils';

const label = '分割线';
const name = 'jd-divider';

export default {
    icon: 'icon-split',
    label,
    name,
    mask: false,
    rule() {
        return {
            type: 'el-divider',
            props: {},
            wrap: {show: false},
            native: false,
            children: [''],
        };
    },
    props(_, {t}) {
        return localeProps(t, name + '.props', [{
            type: 'input',
            field: 'formCreateChild',
            title: '文字内容',
        }, {
            type: 'select',
            field: 'contentPosition',
            title: '文字位置',
            value: 'center',
            options: [{label: '居左', value: 'left'}, {label: '居中', value: 'center'},{label: '居右', value: 'right'}]
        }]);
    }
};
